

import 'package:flutter/services.dart';

class DeviceStatus{

  ///显示状态栏
  static Future<void> show() async {
    await SystemChrome.setEnabledSystemUIMode(SystemUiMode.manual,
        overlays: SystemUiOverlay.values);
  }

  ///隐藏状态栏
  static Future<void> hidden() async {
    await SystemChrome.setEnabledSystemUIMode(SystemUiMode.manual,
        overlays: [SystemUiOverlay.bottom]);
  }

  ///设置状态栏 底部系统横线
  static Future<void> setEnabledSystemUIMode(List<SystemUiOverlay>? overlays) async {
    await SystemChrome.setEnabledSystemUIMode(SystemUiMode.manual,
        overlays: overlays);
  }
}